package demo.service;

import org.springframework.jms.annotation.JmsListener;
import org.springframework.stereotype.Component;

@Component
public class ConsumerService {

    @JmsListener(destination = "myqueue")
    public void consumMessage(String text){
        System.out.println("receive message:"+text);
    }
}
